package com.aaa.demo11;

import java.util.function.Function;

/**
 * @author ${崔灿}
 * @date 2022/11/03 20:19
 **/

public class TestFunction {
    public static void main(String[] args) {
        Function<String , Integer> f = t->t.length();
            fun(f , "哈哈");
    }

    public static void fun(Function<String, Integer> f, String str) {
        Integer apply = f.apply(str);
        System.out.println(apply);
    }
}
